{
  "nbformat": 4,
  "nbformat_minor": 0,
  "metadata": {
    "colab": {
      "private_outputs": true,
      "provenance": [],
      "gpuType": "T4",
      "authorship_tag": "ABX9TyNLaw2RKweysVo2u+qCTuP7",
      "include_colab_link": true
    },
    "kernelspec": {
      "name": "python3",
      "display_name": "Python 3"
    },
    "language_info": {
      "name": "python"
    },
    "accelerator": "GPU"
  },
  "cells": [
    {
      "cell_type": "markdown",
      "metadata": {
        "id": "view-in-github",
        "colab_type": "text"
      },
      "source": [
        "<a href=\"https://colab.research.google.com/github/greengerong/awesome-llm/blob/main/colab/ChatGLM3_demo.ipynb\" target=\"_parent\"><img src=\"https://colab.research.google.com/assets/colab-badge.svg\" alt=\"Open In Colab\"/></a>"
      ]
    },
    {
      "cell_type": "code",
      "execution_count": null,
      "metadata": {
        "id": "4_xdPby3bva6"
      },
      "outputs": [],
      "source": [
        "%cd /content\n",
        "!git clone https://github.com/THUDM/ChatGLM3.git\n",
        "%cd /content/ChatGLM3\n",
        "!pip install -r requirements.txt\n"
      ]
    },
    {
      "cell_type": "markdown",
      "source": [
        "# CLI"
      ],
      "metadata": {
        "id": "JYq1sCIgcZZH"
      }
    },
    {
      "cell_type": "code",
      "source": [
        "!python cli_demo.py"
      ],
      "metadata": {
        "id": "g82pHuqtcau3"
      },
      "execution_count": null,
      "outputs": []
    },
    {
      "cell_type": "markdown",
      "source": [
        "# web-demo"
      ],
      "metadata": {
        "id": "Bsp1dG1hcctp"
      }
    },
    {
      "cell_type": "code",
      "source": [
        "!python web_demo.py"
      ],
      "metadata": {
        "id": "dYyBG9UxceCt"
      },
      "execution_count": null,
      "outputs": []
    }
  ]
}
